package com.jsmile.cloud.authc.api.feign;

import javax.validation.Valid;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.jsmile.cloud.authc.api.constants.AuthcConstants;
import com.jsmile.cloud.authc.api.req.ReqSysUserRegister;
import com.jsmile.cloud.authc.api.res.ResSysUser;
import com.jsmile.mall.api.JSmileResult;

@FeignClient(value = AuthcConstants.APPLICATION_NAME, contextId = "user")
public interface UserServiceApi {

    // TODO 用户注册或者更新用户信息
    @RequestMapping(value = "/feign/user/register", method = RequestMethod.POST)
    JSmileResult<ResSysUser> register(@RequestBody @Valid ReqSysUserRegister reqSysUserRegister);
}
